package com.huike.business.mapper;

import java.util.List;

import com.huike.business.domain.BusinessTrackRecord;
import com.huike.business.domain.BusinessTrackRecordDto;
import com.huike.business.domain.TbBusinessTrackRecord;
import org.apache.ibatis.annotations.Param;

/**
 * 商机跟进记录Mapper接口
 * @date 2021-04-28
 */
public interface TbBusinessTrackRecordMapper {

    /**
     * 查询商机跟进记录列表
     *
     * @param tbBusinessTrackRecord 商机跟进记录
     * @return 商机跟进记录集合
     */
    public List<TbBusinessTrackRecord> selectTbBusinessTrackRecordList(TbBusinessTrackRecord tbBusinessTrackRecord);

    /**
     * 修改商机跟进记录
     *
     * @param tbBusinessTrackRecord 商机跟进记录
     * @return 结果
     */
    public int updateTbBusinessTrackRecord(TbBusinessTrackRecord tbBusinessTrackRecord);

    /**
     * 删除商机跟进记录
     *
     * @param id 商机跟进记录ID
     * @return 结果
     */
    public int deleteTbBusinessTrackRecordById(Long id);

    /**
     * 批量删除商机跟进记录
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    public int deleteTbBusinessTrackRecordByIds(Long[] ids);

    /**
     * 跟进商机id查询商机跟进记录
     * @param id
     * @return
     */
	public List<TbBusinessTrackRecord> selectTbBusinessTrackRecordListByBusinessId(Long id);

    /**
     * 新增商机跟进记录
     * @param businessTrackRecord
     */
    void add(BusinessTrackRecord businessTrackRecord);

    /**
     * 商机跟进记录列表
     * @param businessId
     * @return
     */
    // List<BusinessTrackRecordDto> list(Long businessId);
    /**
     * 根据 id 获取数据库中所有的TbBusinessTrackRecord集合
     * @param id
     * @return
     */
    List<TbBusinessTrackRecord> findBylirbiao(@Param("id") Long id);


    /**
     * 根据keyItems中的每一个id获取相对的字段
     * @param ids
     * @return
     */
    String fianById(@Param("ids") Integer ids);

}
